package org.shiwen.week8.friday;

public class Bicycle extends Transport{
    private boolean isGear;

    public Bicycle(String name, int speed, boolean isGear) {
        super(name, speed);
        this.isGear = isGear;
    }

    public Bicycle(){}

    public boolean isGear() {
        return isGear;
    }

    public void setGear(boolean gear) {
        isGear = gear;
    }

    @Override
    public void moveWay(){
        System.out.println(super.getName()+isGear+"齿轮");
    }
}
